using System.Windows;
using System.Windows.Controls;

namespace GameOverlayWPF
{
    public class CardTemplateSelector : DataTemplateSelector
    {
        public DataTemplate SchemeTemplate { get; set; }
        public DataTemplate AdvertTemplate { get; set; }
        
        public override DataTemplate SelectTemplate(object item, DependencyObject container)
        {
            if (item is Advert)
            {
                return AdvertTemplate;
            }
            else if (item is Scheme)
            {
                return SchemeTemplate;
            }
            
            return base.SelectTemplate(item, container);
        }
    }
}
